#include "mytimer.h"
#include <QtCore>
 int x = 0;

MyTimer::MyTimer()
{
    timer = new QTimer(this);
    connect(timer,SIGNAL(timeout()),this,SLOT(MySlot()));

    timer->start(1000);
}

void MyTimer::MySlot()
{
    x++;
}
